﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using WaterRevenueMS.Domain.Common.Models;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;

namespace WaterRevenueMS.Domain.ViewModels.BasicSet.SysParam
{
    public class SysParamModel : EntityCommon
    {
        public SysParamModel()
        {
            OrderNo = 0;
            Shi_SXS = 2;
            Yong_LQZ = 0;
            Yong_LQZ = 0;
            Dan_JXS = 3;
            Fei_YQZ = 2;
            Fei_YXS = 2;
            Fu_YLBJ = 0;
            Fu_YLGZ = 0;
            Huan_BZQ = 72;
            Huan_BTX = 0;
            Qian_FHB = 0;
            Qian_FBG = 0;
            SetItems = new List<SelectListItem>
            {
                new SelectListItem{Text="四舍五入",Value="0"},
                new SelectListItem{Text="进位",Value="1"},
                new SelectListItem{Text="舍去",Value="2"}
            };

            NegativeCAaramItems = new List<SelectListItem>
            {
                new SelectListItem{Text="不启用",Value="0"},
                new SelectListItem{Text="启用",Value="1"}
            };
            NegativeCRoleItems = new List<SelectListItem>
            {
                new SelectListItem{Text="由操作员人工处理",Value="0"},
                new SelectListItem{Text="用量按零处理",Value="1"},
                new SelectListItem{Text="用量按实际值处理",Value="2"}
            };
            ArrearageItems = new List<SelectListItem>
            {
                new SelectListItem{Text="允许",Value="0"},
                new SelectListItem{Text="不允许",Value="1"}
            };
            Search = new SearchModel();

        }
        public int Id { get; set; }

        [Display(Name="排序序号")]
        public int OrderNo { get; set; }

        #region 用量、费用小数
        [Display(Name="示数小数")]
        public byte Shi_SXS { get; set; }
        [Display(Name = "用量取整")]
        public byte Yong_LQZ { get; set; }
        [Display(Name = "用量小数")]
        public byte Yong_LXS { get; set; }
        [Display(Name = "单价小数")]
        public byte Dan_JXS { get; set; }
        [Display(Name = "费用取整")]
        public byte Fei_YQZ { get; set; }
        [Display(Name = "费用小数")]
        public byte Fei_YXS { get; set; }
        public List<SelectListItem> SetItems { get; set; }
        #endregion 

        #region 负用量报警设置
        [Display(Name="负用量报警")]
        public byte Fu_YLBJ { get; set; }
        public List<SelectListItem> NegativeCAaramItems { get; set; }
        [Display(Name = "负用量规则")]
        public byte Fu_YLGZ { get; set; }
        public List<SelectListItem> NegativeCRoleItems { get; set; }
        #endregion 

        #region 换表设置
        [Display(Name = "换表周期")]
        public byte Huan_BZQ { get; set; }
        [Display(Name = "换表提醒")]
        public byte Huan_BTX { get; set; }
        [Display(Name = "欠费换表")]
        public byte Qian_FHB { get; set; }
        public List<SelectListItem> ArrearageItems { get; set; }
        [Display(Name = "欠费变更")]
        public byte Qian_FBG { get; set; }
        #endregion 

        public SearchModel Search { get; set; }
    }
    public class SearchModel
    {
        public SearchModel()
        {

        }
    }
}
